<html>
<head><meta charset="utf-8"><title>llvm master · t-compiler · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/index.html">t-compiler</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/llvm.20master.html">llvm master</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="223024762"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/llvm%20master/near/223024762" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> devsnek <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/llvm.20master.html#223024762">(Jan 17 2021 at 05:01)</a>:</h4>
<p>is there a way to try compiling rustc with a more recent llvm than is in the forked repo? do i have to just manually replace the submodule?</p>



<a name="223040658"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/llvm%20master/near/223040658" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> bjorn3 <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/llvm.20master.html#223040658">(Jan 17 2021 at 12:34)</a>:</h4>
<p>If you already have LLVM compiled you can specify the <code>llvm-config</code> option in <code>config.toml</code>. I believe it has to be an absolute path.</p>



<a name="223043654"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/llvm%20master/near/223043654" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/llvm.20master.html#223043654">(Jan 17 2021 at 13:51)</a>:</h4>
<p>An absolute path, and without symbolic links I think</p>



<a name="223050492"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/llvm%20master/near/223050492" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/llvm.20master.html#223050492">(Jan 17 2021 at 16:20)</a>:</h4>
<p>It may require some patching for changed LLVM APIs though. I don't think we've done any of that for LLVM 12 (main) yet.</p>



<a name="223053794"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/llvm%20master/near/223053794" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> devsnek <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/llvm.20master.html#223053794">(Jan 17 2021 at 17:29)</a>:</h4>
<p><span class="user-mention" data-user-id="138448">@cuviper</span> how does one tell which commits are rust patches? I found a few but I did it by recompiling llvm and seeing what breaks and then searching for the commit that touches that</p>



<a name="223054162"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/llvm%20master/near/223054162" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/llvm.20master.html#223054162">(Jan 17 2021 at 17:38)</a>:</h4>
<p><span class="user-mention" data-user-id="219805">@devsnek</span> oh, I didn't mean Rust patches to LLVM. Vanilla LLVM is fine if you build it separately from rustc, but using newer than LLVM 11 may have changed some of its C++ APIs, so you'll need to adjust the calls from Rust.</p>



<a name="223054190"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/llvm%20master/near/223054190" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/llvm.20master.html#223054190">(Jan 17 2021 at 17:39)</a>:</h4>
<p>We usually start merging such changes once they branch for a new release, which will be pretty soon for LLVM 12, but I haven't looked at it yet.</p>



<a name="223054426"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/llvm%20master/near/223054426" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> devsnek <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/llvm.20master.html#223054426">(Jan 17 2021 at 17:45)</a>:</h4>
<p>alright i'll try a separate build... still curious about how to find the patches though. a few i've found seem like they <em>should</em> be possible in upstream (in some form or another) and i'd like to look into seeing how many can be removed.</p>



<a name="223055573"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/llvm%20master/near/223055573" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/llvm.20master.html#223055573">(Jan 17 2021 at 18:12)</a>:</h4>
<p>You can use something like <code>git log releases/11.x..</code> from the current rust branch. From there, patches that have LLVM review urls are backported fixes, and otherwise it would be rust specific.</p>



<a name="223056062"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/llvm%20master/near/223056062" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> devsnek <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/llvm.20master.html#223056062">(Jan 17 2021 at 18:24)</a>:</h4>
<p>i can probably grep with that, thanks. maybe next time they're applied they can have <code>[RUST-PATCH]</code> or smth amended into the subject?</p>



<a name="223056630"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/llvm%20master/near/223056630" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> devsnek <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/llvm.20master.html#223056630">(Jan 17 2021 at 18:40)</a>:</h4>
<p><span class="user-mention" data-user-id="138448">@cuviper</span> is there a particular reason this (or something like it) wasn't upstreamed: <a href="https://github.com/rust-lang/llvm-project/commit/c5cf5b45023dcbb246d9fb996d15ec822b9708d7">https://github.com/rust-lang/llvm-project/commit/c5cf5b45023dcbb246d9fb996d15ec822b9708d7</a> ? it seems like a generally useful feature. if not i'll try to upstream the functionality somehow</p>



<a name="223056737"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/llvm%20master/near/223056737" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> cuviper <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/llvm.20master.html#223056737">(Jan 17 2021 at 18:43)</a>:</h4>
<p>We've had that a long while. I'm not sure they'd want those arrays directly exposed, but it would be nice to have that working with external LLVM too.</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>